package com.stox.client.ui.javafx.chartingy.persistence.chart.application;

import com.stox.client.ui.core.application.AbstractApplication;
import com.stox.client.ui.javafx.chartingy.persistence.chart.view.SavedChartView;
import com.stox.shared.core.i18n.MessageSource;

public class SavedChartApplication extends AbstractApplication {

	public static final SavedChartApplication INSTANCE = new SavedChartApplication();
	
	private SavedChartView savedChartView;
	
	@Override
	public String getName() {
		return MessageSource.get("Saved.Charts");
	}
	
	@Override
	public void show() {
		super.show();
		if(null == savedChartView){
			savedChartView = new SavedChartView(getName());
		}
		savedChartView.open();
	}
	
	@Override
	public void hide() {
		savedChartView.close();
		super.hide();
	}

}
